package com.ruoyi.event.domain.bo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * 药物维持治疗业务对象 event_ywwczl
 *
 * @author strongme
 * @date 2023-02-04
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class EventYwwczlBo extends BaseEntity {

    /**
     * id
     */
    @NotNull(message = "id不能为空", groups = {EditGroup.class})
    private Long ywwczlId;

    /**
     * 吸毒人员id
     */
    @NotNull(message = "吸毒人员id不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long userId;

    /**
     * 药物
     */
    @NotBlank(message = "药物不能为空", groups = {AddGroup.class, EditGroup.class})
    private String yw;

    /**
     * 主治医生
     */
    @NotBlank(message = "主治医生不能为空", groups = {AddGroup.class, EditGroup.class})
    private String zzys;

    /**
     * 初次服药时间
     */
    @NotNull(message = "初次服药时间不能为空", groups = {AddGroup.class, EditGroup.class})
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date ccfysj;

    /**
     * 治疗日期
     */
    @NotNull(message = "治疗日期不能为空", groups = {AddGroup.class, EditGroup.class})
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date zlrq;

    /**
     * 服药次数（次/月）
     */
    @NotNull(message = "服药次数（次/月）不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long fycs;

    /**
     * 服药量（总计）
     */
    @NotBlank(message = "服药量（总计）不能为空", groups = {AddGroup.class, EditGroup.class})
    private String fyl;

    /**
     * 治疗地区
     */
    @NotBlank(message = "治疗地区不能为空", groups = {AddGroup.class, EditGroup.class})
    private String zldq;

    /**
     * 治疗单位
     */
    @NotBlank(message = "治疗单位不能为空", groups = {AddGroup.class, EditGroup.class})
    private String zldw;

    /**
     * 备注
     */
    private String remark;


}
